package stcpscheculer;

import java.util.*;

/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

/**
 *
 * @author paulo
 */
public class StcpSchedulerMain {

    /**
     * @param args the command line arguments
     */
    public static void main(String[] args) {
        // TODO read data file and fill configuration file data
        
        //********** Test Data *************
        TestData();
        //********** End Of Test Data ******
        
        GASchedule GA = new GASchedule();
        Chromosome solution = new Chromosome();
        solution = GA.runGA();
        //System.out.println("Starting Print..");
        solution.PrintSolution();
    }
    
    public static void TestData(){
        
        Configuration.setBuses(3);
        Configuration.setDrivers(3);
        Configuration.setTimeSlot(8);
        
        Configuration.setF1(0.2f);
        Configuration.setF2(0.2f);
        Configuration.setF3(0.2f);
        Configuration.setF4(0.2f);
        Configuration.setF5(0.2f);
        
        Configuration.setPopulationSize(10);
        Configuration.setMaxGenerations(3);
        Configuration.setDesiredFA(100);
        
        Configuration.setBusesArr();
        Configuration.setDriversArr();
        Bus b = new Bus(1, "short");
        Configuration.busesArr[0] = b;
        Configuration.busesArr[1] = new Bus(2, "short");
        Configuration.busesArr[2] = new Bus(3, "short");
        
        Set<String> types = new HashSet<String>();
        types.add("short");
        Pair p1 = new Pair(8, 16);
        Pair p2 = new Pair(15, 23);
        Pair p3 = new Pair(0, 8);
        Configuration.driversArr[0] = new Driver(1, types, types, 8, p1);
        Configuration.driversArr[1] = new Driver(2, types, types, 10, p2);
        Configuration.driversArr[2] = new Driver(3, types, types, 6, p3);
        
    }
    
}
